﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using DistributedGraph;

namespace CAP.Forms
{
    /// <summary>
    /// Spezielle Klasse zur Darstellung von Kantenanimationen. (im NodeGraph)
    /// </summary>
    class NodeGraphAnimationLink : NodeGraphAnimation
    {
        #region Attribute
        private Link link;
        private Node from;
        private Node to;
        #endregion Attribute

        #region Eigenschaften
        /// <summary>
        /// Gibt die Kante an die animiert werden soll.
        /// </summary>
        public Link Link { get { return link; } }

        /// <summary>
        /// Gibt den Ausgangsknoten an.
        /// </summary>
        public Node From { get { return from; } }

        /// <summary>
        /// Gibt den Zielknoten an.
        /// </summary>
        public Node To { get { return to; } }
        #endregion Eigenschaften

        #region Methoden
        /// <summary>
        /// Instanziiert und initialisiert die Klasse.
        /// </summary>
        /// <param name="duration">Die Dauer der Animation.</param>
        /// <param name="link">Die betreffende Kante.</param>
        /// <param name="from">Der Ausgangsknoten.</param>
        /// <param name="to">Der Zielknoten.</param>
        public NodeGraphAnimationLink(double duration, Link link, Node from, Node to)
            : base(duration)
        {
            this.link = link;
            this.from = from;
            this.to = to;
        }
        #endregion Methoden
    }
}
